<include file="../Public/header" />
<load href="__PUBLIC__/Js/UserJs.js" />
<style>
.us img{border:1px solid #999; width:100px; height:100px;}
.us_btn{height:27px; line-height:27px; font-size:12px; font-weight:bold; padding:0 10px; text-decoration:underline;}
</style>
<div class="ncenter_box">
<div class="accounttitle"><h1>修改资料 </h1></div>

    <div class="c_p5"><div class="tips">请认真修改自己的个人信息。</div></div>
        <table width="100%" border="0" cellpadding="3" cellspacing="0">
          <form method='post' id="form1" action="__URL__/changedataSave" >
          <tr style="display:none;">
            <td colspan="3" style="height:5px;"></td>
            </tr>
          <tr style="display:none;">
            <td width="25%" height="30" align="right">所属报单中心：</td>
            <td width="25%"><input name="UserID" type="text" id="UserID" value="{$vo['shop_name']}" style="background-color:#ddd;" readonly="readonly" class="ipt" /></td>
            <td width="50%">&nbsp;</td>
            </tr>
          <tr style="display:none;">
            <td width="25%" height="30" align="right">推荐人：</td>
            <td width="25%"><input name="UserID2" type="text" id="UserID2" value="{$vo['re_name']}" style="background-color:#ddd;" readonly="readonly" class="ipt" /></td>
            <td width="50%">&nbsp;</td>
            </tr>
          <tr style="display:none;">
            <td height="30" align="right">接点人：</td>
            <td><input name="UserID3" type="text" id="UserID3" value="{$vo['father_name']}" style="background-color:#ddd;" readonly="readonly"  class="ipt"/></td>
            <td>&nbsp;</td>
            </tr>
        <empty name="User_namex">
        <else/>
        <tr>
        <td height="30" align="right">{$User_namex}：</td>
          <td><input name="UserID" type="text" id="UserID" value="{$vo['user_id']}" style="background-color:#ddd;" readonly="readonly" class="ipt"/></td>
          <td>&nbsp;</td>
        </tr>
        </empty>
          <tr>
            <td height="30" colspan="3" style="height:5px;"><hr></td>
            </tr>
			
			
			<tr  style="display:none;">
          <td align="right">语言：</td>
          <td><select name="Lang" >
              <volist name='lang' id='voo'>
                <eq name='lang[$key]' value="$vo['lang']">
                  <option value="{$lang[$key]}" selected="selected">{$lang[$key]}</option>
                  <else />
                  <option value="{$lang[$key]}">{$lang[$key]}</option>
                </eq>
              </volist>
            </select></td>
          <td>&nbsp;</td>
        </tr>
		
		<tr  style="display:none;">
          <td align="right">国家：</td>
          <td><select name="Countrys">
              <volist name='countrys' id='voo'>
                <eq name='countrys[$key]' value="$vo['countrys']">
                  <option value="{$countrys[$key]}" selected="selected">{$countrys[$key]}</option>
                  <else />
                  <option value="{$countrys[$key]}">{$countrys[$key]}</option>
                </eq>
              </volist>
            </select></td>
          <td>&nbsp;</td>
        </tr>
		
          <tr>
            <td height="30" align="right">级别：</td>
        <td><eq name="agent1" value="0">会员</eq>
        	<eq name="agent1" value="1">会员</eq>
            <eq name="agent1" value="2">报单中心</eq>
            <eq name="agent1" value="3">社区经理</eq>
                  
               
            </td>
            <td>&nbsp;</td>
          </tr>
		
          <tr>
            <td height="30" align="right">开户银行：</td>
        <td><select name="BankName" id="BankName">
                  <volist name='bank' id='voo'>
                     <eq name='bank[$key]' value="$b_bank['bank_name']">
                       <option value="{$bank[$key]}" selected="selected">{$bank[$key]}</option>
                     <else />
                       <option value="{$bank[$key]}">{$bank[$key]}</option>
                     </eq>
                  </volist>
                </select>
            </td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td height="30" align="right"><span id="bank_id">账号</span>：</td>
            <td><input name="BankCard" type="text" id="BankCard" value="{$vo['bank_card']}" class="ipt" maxlength="19" /></td>
            <td></td>
            </tr>
          <tr>
            <td height="30" align="right">开户姓名：</td>
            <td><input name="UserName" type="text" id="UserName" value="{$vo['user_name']}" class="ipt"/></td>
            <td></td>
            </tr>
          <tr>
            <td height="30" align="right">开户省份：</td>
            <td><input name="BankProvince" id="BankProvince" type="text" value="{$vo['bank_province']}" class="ipt" /></td>
            <td></td>
          </tr>
          <tr>
            <td height="30" align="right">开户城市：</td>
            <td><input name="BankCity" id="BankCity" type="text" value="{$vo['bank_city']}" class="ipt" /></td>
            <td></td>
          </tr>
          <tr>
            <td height="30" align="right">详细开户地址：</td>
            <td><input name="BankAddress" type="text" id="BankAddress" value="{$vo['bank_address']}" class="ipt" /></td>
            <td></td>
            </tr>
          <tr>
            <td height="30" colspan="3" style="height:5px;"><hr></td>
            </tr>
          <tr>
            <td height="30" align="right">身份证号：</td>
            <td><input name="UserCode" type="text" id="UserCode" value="{$vo['user_code']}" class="ipt" /></td>
            <td></td>
            </tr>
        
          <tr>
            <td height="30" align="right">微信号：</td>
            <td><input name="UserWeixin" type="text" id="UserWeixin" value="{$vo['weixin']}" class="ipt" onkeyup="javascript:Null_Full(this.name)" onfocus="notice('10','')"  onblur="notice('10','none')"/></td>
            <td><div id="UserAddress1" class="info"><div id="10" class="focus_r" style="display:none;"><div class="msg_tip">请输入微信号。</div></div></div></td>
            </tr>
          <tr>
            <td height="30" align="right">Q Q 号码：</td>
            <td><input name="qq" type="text" id="qq" value="{$vo['qq']}" class="ipt" onkeyup="javascript:Null_Int(this.name)" onfocus="notice('9','')"  onblur="notice('9','none')" maxlength="19" /></td>
            <td><div id="qq1" class="info"><div id="9" class="focus_r" style="display:none;"><div class="msg_tip">请输入号码。</div></div></div></td>
          </tr>
          <tr style="display:none;">
            <td height="30" align="right">联系地址：</td>
            <td><input name="UserAddress" type="text" id="UserAddress" value="{$vo['user_address']}" class="ipt" onkeyup="javascript:Null_Full(this.name)" onfocus="notice('6','')"  onblur="notice('6','none')"/></td>
            <td><div id="UserAddress1" class="info"><div id="6" class="focus_r" style="display:none;"><div class="msg_tip">请输入联系地址。</div></div></div></td>
            </tr>
            
          <tr>
            <td height="30" align="right">联系电话：</td>
            <td><input name="UserTel" type="text" id="UserTel" value="{$vo['user_tel']}" class="ipt" onkeyup="javascript:Null_Full(this.name)" onfocus="notice('7','')"  onblur="notice('7','none')"/></td>
            <td><div id="UserTel1" class="info"><div id="7" class="focus_r" style="display:none;"><div class="msg_tip">请输入联系电话。</div></div></div></td>
            </tr>
          <tr>
            <td height="30" align="right">推荐人手机号：</td>
            <td><input name="UserRephone" type="text" id="UserRephone" value="{$vo['re_phone']}" class="ipt" onkeyup="javascript:Null_Full(this.name)" onfocus="notice('8','')"  onblur="notice('8','none')"/></td>
            <td><div id="UserRephone1" class="info"><div id="8" class="focus_r" style="display:none;"><div class="msg_tip">请输入推荐人手机号。</div></div></div></td>
            </tr>
          <tr>
            <td height="30" align="right">注册时间：</td>
            <td><present name="vo['rdt']">{$vo['rdt']|date='Y-m-d H:i:s',###}
                  <else />
              无</present></td>
            <td>&nbsp;</td>
          </tr>
          <tr>
            <td height="30" align="right">开通时间：</td>
            <td>
            <eq name="vo['is_pay']" value='0'>
            未开通
            <else/>
            {$vo['pdt']|date='Y-m-d H:i:s',###}
            </eq></td>
            <td>&nbsp;</td>
          </tr>
          <tr style="display:none">
            <td height="30" align="right">修改密保问题：</td>
            <td>
          <select name="xg_wenti">
            	<option value="">选择密保问题</option>
              <volist name='wentilist' id='voo'>
                  <option value="{$voo}" <eq name="voo" value="$vo['wenti']">selected</eq> >{$voo}</option>
              </volist>
            </select></td>
            <td></td>
          </tr>
          <tr style="display:none">
            <td height="30" align="right">修改密保答案：</td>
            <td><input name="xg_wenti_dan" type="text" id="xg_wenti_dan" value="" class="ipt"/></td>
            <td><div class="info"><div class="focus_r"><div class="msg_tip">不修改请留空。</div></div></div></td>
          </tr>
          <tr style="display:none">
            <td height="30" colspan="3" style="height:5px;"><hr></td>
          </tr>
          <tr style="display:none">
            <td height="30" align="right">昵称：</td>
              <td><input name="NickName" type="text" id="NickName" value="{$vo['nickname']}" class="ipt"/></td>
              <td></td>
          </tr>
          <tr style="display:none">
            <td height="30" align="right">密保问题：</td>
            <td>{$vo['wenti']}</td>
            <td>&nbsp;</td>
            </tr>
          <tr style="display:none">
            <td height="30" align="right">请回答密保答案：</td>
            <td><input name="wenti_dan" type="text" id="wenti_dan" value="" class="ipt"/></td>
            <td>&nbsp;</td>
          </tr>
          <tr style="display:none">
            <td height="30" align="right">用户头像：</td>
            <td class="us" colspan="2">
            <div id="addImageURL" style="display:none">
			<input name="image2" type="text" id="image2" value="" size="50" maxlength="500" />
			<input name="image" type="text" id="image"  value="{$vo['us_img']}" size="50" maxlength="500" style="display:none" />
			<input type="button" id="addImg" value="添加" onClick="addNetImg();"><br>
            </div>
            <div id="uploadImg">
                <iframe id="frmPic" name="frmPic" src="__URL__/uploadImg" width="480" height="320" scrolling="no" frameborder="0"></iframe>
            </div>
            <div style="display:none">
                <img style="height:225px;width:330px;" id="imageShow" alt="商品图像" src="{$vo['us_img']}">
            </div>
            </td>
          </tr>
          <tr>
            <td colspan="3" style="height:5px;"><hr></td>
            </tr>
          <tr>
          <tr>
            <td height="25" colspan="3" align="center">
            <input type="hidden" name="ID" value="{$vo['id']}" >
            <input type="submit" value="修改" class="button_text">&nbsp;&nbsp;
            <input name="重置" type="reset" class="button_text" value="重置"></td>
          </tr>
          </form>
        </table>
</div>
</body>
</html>
<script>
var i=document.getElementById("BankName").selectedIndex;
function setDefault() {
    document.getElementById("BankName").selectedIndex=i;
}
</script>
<script>
function addNetImg(){
	var str = document.getElementById('image2').value;
	document.getElementById('image').value = str;
	document.getElementById('imageShow').src = str;
	window.frames["frmPic"].document.getElementById('crop-preview-100').src=str;
}
function changeType(type){
	
	switch(type){
		case 1:
			document.getElementById('addImageURL').style.display='none';
			document.getElementById('uploadImg').style.display='block';
			window.frames["frmPic"].document.getElementById('selectImg').style.display='block';
			window.frames["frmPic"].document.getElementById('saveImg').style.display='block';
			window.frames["frmPic"].document.getElementById('cancelImg').style.display='block';
			break;
		case 2:
			document.getElementById('addImageURL').style.display='block';
			window.frames["frmPic"].document.getElementById('selectImg').style.display='none';
			window.frames["frmPic"].document.getElementById('saveImg').style.display='none';
			window.frames["frmPic"].document.getElementById('cancelImg').style.display='none';
			break;
		default:
	}
}

</script>